﻿using Shop.Model.DB;
using Shop.RemoteModel.LogisticsConfig.Model;
using WeDonekRpc.Model;

namespace Shop.Collect
{
    public interface ILogisticsConfigCollect
    {
        LogisticsPrice CalculatePrice (CalculateLogistics param);
        long Add (LogisticsConfigAdd add);
        void Clear (long templateId);
        bool SetIsEnable (DBLogisticsConfig config, bool enable);
        void Delete (DBLogisticsConfig config);
        DBLogisticsConfig Get (long id);

        Result Get<Result> (long id) where Result : class;
        Result[] Query<Result> (LQueryParam query, IBasicPage paging, out int count) where Result : class;
        bool Set (DBLogisticsConfig config, LogisticsConfigSet set);
        Result[] Gets<Result> (LQueryParam query) where Result : class, new();
    }
}